<template>
    <el-pagination background layout="prev, pager, next,total,jumper" :total="total" small :page-size="30"
                   :current-page="page" next-text="下一页" prev-text="上一页" hide-on-single-page
                   @current-change="getData"/>
</template>

<script setup>
import { defineProps, defineEmits} from "vue";

defineProps({
    total: {
        type: Number,
        default: () => 0
    },
    page: {
        type: Number,
        default: () => 1
    }
})
const emit = defineEmits(['getData'])
const getData = (page) => {
    emit("getData", page)
}
</script>

<style scoped>
.el-pagination{
    justify-content: right;
    padding-right: 15px;
    margin-top: 15px;
}
</style>
